﻿using BCData.OA.TeamWorks.TaskResourceRecord;
using BCDto.OA.TeamWorks.TaskResourceRecord;
using BCService.Utils;
using System;
using System.Collections.Generic;
using System.Text;

namespace BCService.OA.TeamWorks.TaskResourceRecord
{
    public class TaskResourceRecordService: ITaskResourceRecordService
    {
        private readonly ITaskResourceRecordData taskResourceRecordData;

        public TaskResourceRecordService(ITaskResourceRecordData taskResourceRecordData)
        {
            this.taskResourceRecordData = taskResourceRecordData;
        }

        public TaskResourceRecordDto Add(TaskResourceRecordRequestDto requestDto)
        {
            throw new NotImplementedException();
        }

        public IEnumerable<TaskResourceRecordDto> GetList(long workflowActivityInstanceId)
        {
            return this.taskResourceRecordData.GetList(workflowActivityInstanceId).GetAwaiter().GetResult().As<IEnumerable<TaskResourceRecordDto>>();
        }
    }
}
